Geographical location information is one piece of data most favorably collected by various applications (APPs) on an intelligent terminal, and is also key data on which many APPs depend when performing their core services. Location information is generally indicated using location coordinates. As important geographical data with a context, the location coordinates disclose user privacy, and even a business secret. For example, a user appears in a mental hospital for multiple times, which may imply that the user may suffer from some sort of mental disorder; a chief executive officer (CEO) of a large company repeatedly appears in a location of another company, which may imply that the company is planning acquisition or an important commercial transaction. Therefore, to avoid that an APP excessively collects location information of a user, it is imperative to protect user privacy. The location information is core data on which service logic of many APPs depends. If location data cannot be obtained, many functions cannot be properly performed (such as a map, a location-based query, and location-based social contact).
The intelligent terminal can use multiple types of devices and facilities to acquire the location information, such as a global positioning system (GPS), and a radio base station. It takes a long time to perform positioning by the GPS, and power consumption in a process is relatively large; however, positioning accuracy is relatively high. A positioning speed of the radio base station is high, and power consumption in a process is small; however, accuracy is lower than the accuracy of the GPS. On the intelligent terminal, various APPs use a unified location application programming interface (API) to read current location data of the intelligent terminal. The location data is returned to the APPs in a form of longitude and latitude coordinates, such as (124.123, 87.231). Because a location is an important data resource, an operating system of the intelligent terminal uses a right to protect the resource. When an APP invokes an API to read a terminal location, the operating system first checks whether the APP obtains a corresponding right; if there is no such a right, the APP is rejected accessing the location.
According to some existing APP right management solutions, such as a mobile phone manager, and a security manager, a user is allowed to deprive an installed APP of a right of reading a geographical location, so that the APP cannot read a location of the user. Once a location right is deprived, the APP cannot read a real location of the user, which affects a normal service function of the APP, such as a map location query, and location-based social contact. Although the user can reassign the location right to the APP, the user needs to decide time of depriving the location right of that type of APP, and time of reassigning the location right to that type of APP.
This process is repetitive and cumbersome, and the user needs to have special knowledge to determine whether each type of APP can read the location data at this time, which affects normal running of the APP. In addition, a manual operation is slow and difficult to ensure that the APP does not read a location that the user does not want the APP to read, which causes poor protection for location information.